﻿using iBing.Common.DbHelper;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace CodeTemplate.CodeEdit
{
    public class ToolForGetDbPk
    {

        public static string GetPkFieldName(List<DbField> dbFields)
        {
            string pkDbField = "";
            foreach (DbField of in dbFields)
            {
                if (of.IsPk)
                {
                    pkDbField = of.FieldName;
                    break;
                }
            }
            return pkDbField;
   
        }
    }
}
